package com.dizang.es.utils;


public class ResultUtil {

    public static BaseRespone resultCode(int code,String msg) {
        BaseRespone baseRespone = new BaseRespone();
        baseRespone.setCode(code);
        baseRespone.setMsg(msg);
        return baseRespone;
    }

    public static BaseRespone resultSuccess(Object result) {
        BaseRespone baseRespone = new BaseRespone();
        baseRespone.setCode(200);
        baseRespone.setObject(result);
        return baseRespone;
    }

    public static BaseRespone resultError(Object result) {
        BaseRespone baseRespone = new BaseRespone();
        baseRespone.setCode(500);
        baseRespone.setObject(result);
        return baseRespone;
    }

}
